@echo off

rem *** PEGA home ***
set PEGA_HOME=c:\pega

rem *** Java ***
set JAVA_HOME=%PEGA_HOME%\apps\java\jdk1.6
set Path=%JAVA_HOME%\bin;%Path%

rem *** metadata ***
if exist workspace\.metadata goto metadataexists
set TOOLS=%PEGA_HOME%\tools
set ZIP=%TOOLS%\7-Zip\7z.exe
echo %ZIP% x -y -oworkspace workspace\metadata.zip
%ZIP% x -y -oworkspace workspace\metadata.zip
:metadataexists

rem *** make this branch the active PRPC instance (for AppStore purposes)
call setAsActiveBranchForAppStore.cmd nopause

rem *** Start Eclipse and Oracle concurrently, if Oracle is already running the start file will fall through quickly ***
start %PEGA_HOME%\tools\start_Oracle.bat

start %PEGA_HOME%/apps/eclipse361/eclipse.exe -clean -configuration configuration.eclipse.361/configuration -showlocation -data workspace
